/*
 * Copyright (c) 2020 - present, Inspur Genersoft Co., Ltd.
 *
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *       http://www.apache.org/licenses/LICENSE-2.0
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */

package com.inspur.edp.bff.engine.core.action;

import com.inspur.edp.bff.api.manager.assembler.*;
import com.inspur.edp.bff.engine.core.action.cancel.BffEngineCancelAssember;
import com.inspur.edp.bff.engine.core.action.changemap.BffEngineChangeMapperAssembler;
import com.inspur.edp.bff.engine.core.action.datamap.BffEngineDataMapAssembler;
import com.inspur.edp.bff.engine.core.action.delete.BffEngineDeleteAssembler;
import com.inspur.edp.bff.engine.core.action.delete.BffEngineDeleteChildAssembler;
import com.inspur.edp.bff.engine.core.action.modify.BffEngineModifyAssembler;
import com.inspur.edp.bff.engine.core.action.query.BffEngineQueryAssembler;
import com.inspur.edp.bff.engine.core.action.retrieve.BffEngineRetrieveAssembler;
import com.inspur.edp.bff.engine.core.action.retrievedefault.BffEngineRetrieveDefaultAssembler;
import com.inspur.edp.bff.engine.core.action.retrievedefault.BffEngineRetrieveDefaultChildAssembler;
import com.inspur.edp.bff.engine.core.action.save.BffEngineSaveAssembler;
import com.inspur.edp.bff.spi.assembler.AbstractAssemblerManager;
import com.inspur.edp.formserver.viewmodel.GspViewModel;

public class BffEngineAssemblerManager extends AbstractAssemblerManager {

    private GspViewModel vo;
    public BffEngineAssemblerManager(GspViewModel vo){
        this.vo = vo;
    }
    @Override
    public IExtendQueryAssembler getQueryAssembler() {
        return new BffEngineQueryAssembler(vo);
    }

    @Override
    public IDataMapperAssembler getDataMapperAssembler() {
        return new BffEngineDataMapAssembler(vo);
    }

    @Override
    public IExtendRetrieveAssembler getRetrieveAssembler() {
        return new BffEngineRetrieveAssembler(vo);
    }

    @Override
    public IExtendRetrieveDefaultAssembler getRetrieveDefaultAssembler() {
        return new BffEngineRetrieveDefaultAssembler(vo);
    }

    @Override
    public IExtendDeleteAssembler getDeleteAssembler() {
        return new BffEngineDeleteAssembler(vo);
    }

    @Override
    public IChangeMapperAssembler getChangeMapperAssembler() {
        return new BffEngineChangeMapperAssembler(vo);
    }

    @Override
    public IExtendModifyAssembler getModifyAssembler() {
        return new BffEngineModifyAssembler(vo);
    }

    @Override
    public IExtendSaveAssembler getSaveAssembler() {
        return new BffEngineSaveAssembler(vo);
    }

    @Override
    public IExtendRetrieveDefaultChildAssembler getRetrieveDefaultChildAssembler() {
        return BffEngineRetrieveDefaultChildAssembler.build(vo);
    }

    @Override
    public IExtendDeleteChildAssembler getDeleteChildAssembler() {
        return BffEngineDeleteChildAssembler.build(vo);
    }

    public IExtendCancelAssember getCancelAssember() {
        return BffEngineCancelAssember.build(vo);
    }
}
